package br.com.musclebook.error;

import javax.ejb.ApplicationException;

@ApplicationException(rollback = true)
public class MusclebookException extends RuntimeException {

    private static final long serialVersionUID = 1L;
    
    String message;
    
    public MusclebookException(){}
    
    public MusclebookException(String message) {
	this.message = message;
    }
    
    @Override
    public String getMessage() {
        if(this.message != null)
            return this.message;
        else
            return super.getMessage();
    }

}
